------------------------------------------------------------------------------------------------------------------
      name:  <unnamed>
       log:  C:\Users\sgolder\Dropbox\Portfolio Allocation\replication\warwickdruckman.log
  log type:  text
 opened on:  30 Mar 2017, 13:32:14

. set more off

. #delimit ;
delimiter now ;
. *     ***************************************************************** *;
. *     ***************************************************************** *;
. *       File-Name:      warwick_druckman_data.do                        *;
. *       Date:           August 16, 2016                                 *;
. *       Author:         Molly Ariotti and Sona Golder                   *;
. *       Purpose:        Take original Warwick and Druckman (2006) data  *;
. *                       and put it in more useful format.               *;
. *           Input File:     wtportfolios5.dta                               *;
. *       Output File:    warwickdruckman.log                             *;
. *       Data Output:    Europe.dta                                      *;
.              *       Previous file:  none                                            *;
. *       Machine:        laptop                                                          *;
. *     ****************************************************************  *;
. *     ****************************************************************  *;
. *     ****************************************************************  *;
. *       Open and summarize dataset.                                     *;
. *     ****************************************************************  *;
. use "C:\Users\sgolder\Dropbox\Portfolio Allocation\replication\wtportfolios5.dta";

. sum;

    Variable |        Obs        Mean    Std. Dev.       Min        Max
-------------+---------------------------------------------------------
      caseno |        807    692.9765    393.8148        101       1625
       nptys |        807    3.389095    1.123748          2          6
      sample |        807    .6679058    .4712566          0          1
         df2 |        807    6.439901    3.183946          1         12
         df1 |        807     1837.03    490.8286         59       1999
-------------+---------------------------------------------------------
       party |        807     8.30855    3.828548          1         24
       seats |        807    57.07311    70.83576          2        319
        form |        807    .3209418     .467128          0          1
       port1 |        744    .3293011    .4702756          0          1
       port2 |        576    .3350694     .472425          0          1
-------------+---------------------------------------------------------
       port3 |        650    .3276923    .4697335          0          1
       port4 |        484    .3409091    .4745053          0          1
       port5 |        514    .3404669    .4743279          0          1
       port6 |        655    .3282443    .4699331          0          1
       port7 |        575         .32    .4668823          0          1
-------------+---------------------------------------------------------
       port8 |        513    .3294347    .4704667          0          1
       port9 |        567    .3262787    .4692646          0          1
      port10 |        501    .3413174    .4746256          0          1
      port11 |        484     .322314    .4678461          0          1
      port12 |        554    .3140794    .4645677          0          1
-------------+---------------------------------------------------------
      port13 |        448    .3169643    .4658135          0          1
      port14 |        428    .3107477    .4633413          0          1
      port15 |        413    .3099274    .4630243          0          1
      port16 |        378    .3253968    .4691439          0          1
      port17 |        383    .3342037    .4723283          0          1
-------------+---------------------------------------------------------
      port18 |        320      .33125    .4713999          0          1
      port19 |        271    .3542435    .4791683          0          1
      port20 |        339    .3480826    .4770665          0          1
      port21 |        247    .3603239    .4810692          0          1
      port22 |        180    .3555556    .4800166          0          1
-------------+---------------------------------------------------------
      port23 |        347    .2997118    .4587932          0          1
      port24 |        187    .3315508    .4720343          0          1
      port25 |        240       .3125    .4644811          0          1
      port26 |        284    .3239437    .4688049          0          1
      port27 |        301    .3122924    .4642001          0          1
-------------+---------------------------------------------------------
      port28 |        348     .295977     .457138          0          1
      port29 |        306    .3071895    .4620843          0          1
      port30 |        289    .3079585    .4624501          0          1
      port31 |        276    .2934783    .4561828          0          1
      port32 |        181    .3259669    .4700352          0          1
-------------+---------------------------------------------------------
      port33 |        163    .3374233    .4742878          0          1
      port34 |        135    .3111111    .4646724          0          1
      port35 |        184    .3315217    .4720446          0          1
      port36 |        114    .3421053    .4765092          0          1
      port37 |        150    .3333333    .4729838          0          1
-------------+---------------------------------------------------------
      port38 |        135    .3185185     .467637          0          1
      port39 |        106    .3113208    .4652333          0          1
      port40 |        103    .3203883    .4689076          0          1
      port41 |         71    .3239437    .4713097          0          1
      port42 |         78    .2948718    .4589365          0          1
-------------+---------------------------------------------------------
      port43 |         59    .3559322    .4829047          0          1
      port44 |         23    .5217391    .7304771          0          3
      port45 |         99    .2727273    .4476283          0          1
      port46 |         95    .2631579    .4426835          0          1
      port47 |         61    .3114754    .4669398          0          1
-------------+---------------------------------------------------------
      port48 |         53     .245283    .4343722          0          1
      port49 |         46    .3043478    .4652151          0          1
      port50 |         62    .2741935    .4497487          0          1
      port51 |         48    .2708333    .4490929          0          1
      port52 |         37    .2972973    .4633732          0          1
-------------+---------------------------------------------------------
      port53 |         47    .2553191    .4407545          0          1
      port54 |         25         .32    .4760952          0          1
      port55 |         73    .2876712    .4558098          0          1
      port56 |         80       .2625    .4427689          0          1
      port57 |         25          .4          .5          0          1
-------------+---------------------------------------------------------
      port58 |         10          .4    .5163978          0          1
      port59 |         14    .3571429    .4972452          0          1
      port60 |         19    .2631579    .4524139          0          1
      port61 |          6          .5    .5477226          0          1
      port62 |          6          .5    .5477226          0          1
-------------+---------------------------------------------------------
      port63 |         10          .4    .5163978          0          1
      port64 |         10          .4    .5163978          0          1
      port65 |          4          .5    .5773503          0          1
      port66 |          4          .5    .5773503          0          1
      port67 |          4          .5    .5773503          0          1
-------------+---------------------------------------------------------
      port68 |         19    .4736842    .5129892          0          1
      port69 |          5          .4    .5477226          0          1
      port70 |         14    .4285714    .5135526          0          1
      port71 |          8          .5    .5345225          0          1
      port72 |         13    .3076923    .4803845          0          1
-------------+---------------------------------------------------------
      port73 |          6          .5    .5477226          0          1
      port74 |          7    .4285714    .5345225          0          1
      port75 |         20          .3    .4701623          0          1
      port76 |         26    .2692308    .4523443          0          1
      port77 |          4          .5    .5773503          0          1
-------------+---------------------------------------------------------
      port78 |          5          .2    .4472136          0          1
      port79 |         14    .2142857    .4258153          0          1
      port80 |         41    .2439024    .4347694          0          1
      port81 |          9    .2222222    .4409586          0          1
      port82 |         64     .234375    .4269563          0          1
-------------+---------------------------------------------------------
      port83 |          9    .2222222    .4409586          0          1
      port84 |         19    .2105263    .4188539          0          1
      port85 |         28    .2142857    .4178554          0          1
      port86 |         14    .2142857    .4258153          0          1
      port87 |         28    .2142857    .4178554          0          1
-------------+---------------------------------------------------------
      port88 |         31    .2258065    .4250237          0          1
      port89 |         33    .2121212    .4151488          0          1
      port90 |          5          .2    .4472136          0          1
      port91 |          8         .25      .46291          0          1
      port92 |         13    .2307692     .438529          0          1
-------------+---------------------------------------------------------
      port93 |          5          .2    .4472136          0          1
      port94 |          0
      port95 |          0
      port96 |          9    .2222222    .4409586          0          1
      port97 |         23    .2173913    .4217412          0          1
-------------+---------------------------------------------------------
      port98 |         14    .2142857    .4258153          0          1
      port99 |          6    .1666667    .4082483          0          1
     port100 |          6    .1666667    .4082483          0          1
     port101 |          9    .2222222    .4409586          0          1
     port102 |          5          .2    .4472136          0          1
-------------+---------------------------------------------------------
     port103 |          4         .25          .5          0          1
     port104 |          4         .25          .5          0          1
     port105 |          4         .25          .5          0          1
     port106 |          4         .25          .5          0          1
     port107 |          8         .25      .46291          0          1
-------------+---------------------------------------------------------
     port108 |          4         .25          .5          0          1
     port109 |          4         .25          .5          0          1
     port110 |          4         .25          .5          0          1
     port111 |          6    .1666667    .4082483          0          1
     port112 |          6    .1666667    .4082483          0          1
-------------+---------------------------------------------------------
     port113 |          6    .1666667    .4082483          0          1
     port114 |          6    .1666667    .4082483          0          1
     port115 |          6    .1666667    .4082483          0          1
     port116 |          6    .1666667    .4082483          0          1
     port117 |          6    .1666667    .4082483          0          1
-------------+---------------------------------------------------------
     port118 |          0
     port119 |          0
     port120 |          0
     country |        807    6.692689     3.96789          1         16
    casetype |        807    1.032218    .2519461          1          3
-------------+---------------------------------------------------------
     w1port1 |        807    2.294378    .2350349          2       2.75
     w1port2 |        807    1.523332    .3638478   .6727273      2.115
     w1port3 |        807    1.488817    .2226849      .9875   1.780769
     w1port4 |        807    1.099845    .5216554          0   1.642857
     w1port5 |        807    .8702833    .4511283          0        1.5
-------------+---------------------------------------------------------
     w1port6 |        807    1.212459    .3791447   .3658333       1.92
     w1port7 |        807    1.103242    .3504784       .627   1.679167
     w1port8 |        807    .8334237    .2526466          0   1.227273
     w1port9 |        807    .9683481    .4532784          0       1.83
    w1port10 |        807    .8557553    .3928197          0   1.333333
-------------+---------------------------------------------------------
    w1port11 |        807    .8016888      .39079          0       1.46
    w1port12 |        807    .9856128    .1861686   .4953846   1.258333
    w1port13 |        807     .806957    .4012885          0   1.191667
    w1port14 |        807     .898255    .4050874          0   1.273333
    w1port15 |        807     .857816    .1555153   .5563636   1.266667
-------------+---------------------------------------------------------
    w1port16 |        807    .8709154    .3075857          0   1.227273
    w1port17 |        807    .7987285     .318529          0      1.185
    w1port18 |        807    .6045616    .3400353          0        1.3
    w1port19 |        807    .6558079    .4398247          0        1.3
    w1port20 |        807    .8153954    .3044621          0      1.275
-------------+---------------------------------------------------------
    w1port21 |        807    .7444405    .4619039          0       1.58
    w1port22 |        807    .6410052    .5515379          0       1.58
    w1port23 |        807    .7489491    .3671913          0      1.225
    w1port24 |        807    .7062132    .3528432          0   1.097059
    w1port25 |        807    .5242255    .3647512          0        1.1
-------------+---------------------------------------------------------
    w1port26 |        807    .7161039    .6511994          0       2.01
    w1port27 |        807    .6665331     .657642          0       1.78
    w1port28 |        807     .422852    .4200217          0      1.225
    w1port29 |        807     .656415    .4103865          0       1.23
    w1port30 |        807    .5665879     .387178          0      1.225
-------------+---------------------------------------------------------
    w1port31 |        807      .44091    .3621546          0      1.225
    w1port32 |        807    .4516189    .3971223          0      1.225
    w1port33 |        807    .5720735    .4120526          0      1.082
    w1port34 |        807     .439178    .4096766          0      1.025
    w1port35 |        807    .5833254    .4497025          0       1.58
-------------+---------------------------------------------------------
    w1port36 |        807    .4241367    .4673484          0       1.58
    w1port37 |        807    .3824019    .3617902          0   1.333333
    w1port38 |        807    .4017761    .4501514          0   1.333333
    w1port39 |        807    .3513602    .4086414          0      1.025
    w1port40 |        807     .335392    .3948089          0   1.086364
-------------+---------------------------------------------------------
    w1port41 |        807    .1137772    .3027151          0   .9181818
    w1port42 |        807     .320747    .3792423          0   .9181818
    w1port43 |        807    .1232962    .3280413          0       .995
    w1port44 |        807    .2139405    .3473921          0       .995
    w1port45 |        807    .2646427    .4670973          0   1.404167
-------------+---------------------------------------------------------
    w1port46 |        807    .2646427    .4670973          0   1.404167
    w1port47 |        807    .1964891    .3090988          0   .8541667
    w1port48 |        807    .1964891    .3090988          0   .8541667
    w1port49 |        807    .1717528     .259415          0   .6545454
    w1port50 |        807    .1717528     .259415          0   .6545454
-------------+---------------------------------------------------------
    w1port51 |        807    .1815159    .2782259          0   .7333333
    w1port52 |        807    .1815159    .2782259          0   .7333333
    w1port53 |        807    .1670591    .2508271          0   .6166667
    w1port54 |        807    .1983726    .2946965          0      .6475
    w1port55 |        807    .2714519    .3969465          0       .975
-------------+---------------------------------------------------------
    w1port56 |        807    .2064746    .3502654          0       .975
    w1port57 |        807    .1094589    .2912259          0   .8833333
    w1port58 |        807    .0580752    .2614154          0   1.233333
    w1port59 |        807           0           0          0          0
    w1port60 |        807           0           0          0          0
-------------+---------------------------------------------------------
    w1port61 |        807           0           0          0          0
    w1port62 |        807     .062784    .2826112          0   1.333333
    w1port63 |        807    .0250979    .1129738          0       .533
    w1port64 |        807    .0250979    .1129738          0       .533
    w1port65 |        807           0           0          0          0
-------------+---------------------------------------------------------
    w1port66 |        807           0           0          0          0
    w1port67 |        807           0           0          0          0
    w1port68 |        807    .2752168    .7322409          0      2.221
    w1port69 |        807    .2752168    .7322409          0      2.221
    w1port70 |        807           0           0          0          0
-------------+---------------------------------------------------------
    w1port71 |        807    .1352747    .3599113          0   1.091667
    w1port72 |        807           0           0          0          0
    w1port73 |        807           0           0          0          0
    w1port74 |        807    .1019489    .2712447          0   .8227273
    w1port75 |        807    .1019489    .2712447          0   .8227273
-------------+---------------------------------------------------------
    w1port76 |        807    .1019489    .2712447          0   .8227273
    w1port77 |        807    .1019489    .2712447          0   .8227273
    w1port78 |        807    .1019489    .2712447          0   .8227273
    w1port79 |        807    .1450847    .3860117          0   1.170833
    w1port80 |        807    .1450847    .3860117          0   1.170833
-------------+---------------------------------------------------------
    w1port81 |        807    .1450847    .3860117          0   1.170833
    w1port82 |        807    .1450847    .3860117          0   1.170833
    w1port83 |        807    .1182832    .3147038          0   .9545454
    w1port84 |        807    .1182832    .3147038          0   .9545454
    w1port85 |        807    .1182832    .3147038          0   .9545454
-------------+---------------------------------------------------------
    w1port86 |        807    .1182832    .3147038          0   .9545454
    w1port87 |        807    .1182832    .3147038          0   .9545454
    w1port88 |        807    .1182832    .3147038          0   .9545454
    w1port89 |        807           0           0          0          0
    w1port90 |        807    .1208178    .3214475          0       .975
-------------+---------------------------------------------------------
    w1port91 |        807    .1208178    .3214475          0       .975
    w1port92 |        807    .1208178    .3214475          0       .975
    w1port93 |        807           0           0          0          0
    w1port94 |        807           0           0          0          0
    w1port95 |        807           0           0          0          0
-------------+---------------------------------------------------------
    w1port96 |        807    .1019489    .2712447          0   .8227273
    w1port97 |        807    .1019489    .2712447          0   .8227273
    w1port98 |        807    .1019489    .2712447          0   .8227273
    w1port99 |        807    .1019489    .2712447          0   .8227273
    w1por100 |        807    .1019489    .2712447          0   .8227273
-------------+---------------------------------------------------------
    w1por101 |        807           0           0          0          0
    w1por102 |        807           0           0          0          0
    w1por103 |        807           0           0          0          0
    w1por104 |        807           0           0          0          0
    w1por105 |        807           0           0          0          0
-------------+---------------------------------------------------------
    w1por106 |        807           0           0          0          0
    w1por107 |        807           0           0          0          0
    w1por108 |        807           0           0          0          0
    w1por109 |        807    .1135894    .3022156          0   .9166667
    w1por110 |        807           0           0          0          0
-------------+---------------------------------------------------------
    w1por111 |        807           0           0          0          0
    w1por112 |        807           0           0          0          0
    w1por113 |        807           0           0          0          0
    w1por114 |        807           0           0          0          0
    w1por115 |        807           0           0          0          0
-------------+---------------------------------------------------------
    w1por116 |        807           0           0          0          0
    w1por117 |        807           0           0          0          0
    w1por118 |        807           0           0          0          0
    w1por119 |        807           0           0          0          0
    w1por120 |        807           0           0          0          0
-------------+---------------------------------------------------------
     w2port1 |        807    2.294378    .2350349          2       2.75
     w2port2 |        807    1.523332    .3638478   .6727273      2.115
     w2port3 |        807    1.488817    .2226849      .9875   1.780769
     w2port4 |        807    1.337299    .2390938       .512   1.642857
     w2port5 |        807    1.038034    .2547492   .5607143        1.5
-------------+---------------------------------------------------------
     w2port6 |        807    1.212459    .3791447   .3658333       1.92
     w2port7 |        807    1.103242    .3504784       .627   1.679167
     w2port8 |        807    .9052948     .103305       .715   1.227273
     w2port9 |        807    1.098769    .2132642       .842       1.83
    w2port10 |        807    .9479176    .2068213       .595   1.333333
-------------+---------------------------------------------------------
    w2port11 |        807    .8478474    .3004237       .298       1.46
    w2port12 |        807    .9856128    .1861686   .4953846   1.258333
    w2port13 |        807    .9629359    .2046695   .4953846   1.191667
    w2port14 |        807    1.008385    .1796008       .711   1.273333
    w2port15 |        807     .857816    .1555153   .5563636   1.266667
-------------+---------------------------------------------------------
    w2port16 |        807    .9427866    .1898807   .6318182   1.227273
    w2port17 |        807    .8705996    .2308585        .35      1.185
    w2port18 |        807    .7258441    .2217001   .3772727        1.3
    w2port19 |        807    .8244882     .272016       .324        1.3
    w2port20 |        807    .9157671    .1386293   .5022727      1.275
-------------+---------------------------------------------------------
    w2port21 |        807    .9163736    .2744967     .30625       1.58
    w2port22 |        807    .9622567    .2685945   .5022727       1.58
    w2port23 |        807    .8983221    .1758267       .606      1.225
    w2port24 |        807    .8809343    .1475938      .6475   1.097059
    w2port25 |        807     .734078    .3362708          0      1.722
-------------+---------------------------------------------------------
    w2port26 |        807    1.193026    .6252662       .584      2.393
    w2port27 |        807    1.232211    .4608793   .5336364      2.118
    w2port28 |        807    .9998743    .4622617       .245      2.176
    w2port29 |        807    .9410284     .384941       .245      1.704
    w2port30 |        807    .8965457    .4511184          0      2.068
-------------+---------------------------------------------------------
    w2port31 |        807    .8917898    .5429358          0       2.36
    w2port32 |        807    .9132979    .5443318          0      2.205
    w2port33 |        807    .9460128    .4847965          0       2.15
    w2port34 |        807    .9273379    .6174312          0       2.36
    w2port35 |        807    .8682932    .5613725          0      2.117
-------------+---------------------------------------------------------
    w2port36 |        807    .9776386    .6456042          0      2.258
    w2port37 |        807    .7641132    .5432536          0       2.38
    w2port38 |        807    .9538926    .6420239          0       2.24
    w2port39 |        807    .8172004    .4400878          0       1.75
    w2port40 |        807    .8480389    .6478138          0      2.229
-------------+---------------------------------------------------------
    w2port41 |        807    .7619519    .6927437          0      2.498
    w2port42 |        807    .7880121    .6444914          0      3.066
    w2port43 |        807    .4957621      .55892          0      1.717
    w2port44 |        807    .7602639    .6697215          0      3.138
    w2port45 |        807    .7099748    .6448976          0      2.441
-------------+---------------------------------------------------------
    w2port46 |        807    .6568038    .6450562          0      2.156
    w2port47 |        807    .4193478    .3874347          0      1.303
    w2port48 |        807     .387784    .4210952          0      1.083
    w2port49 |        807    .3318904     .343682          0      1.062
    w2port50 |        807    .3209164    .3278828          0       .811
-------------+---------------------------------------------------------
    w2port51 |        807    .3517451     .362885          0          1
    w2port52 |        807    .3156547    .3267517          0          1
    w2port53 |        807    .3690417    .3958915          0          1
    w2port54 |        807    .4003552    .4098739          0          1
    w2port55 |        807    .7647456    .9691861          0      2.619
-------------+---------------------------------------------------------
    w2port56 |        807    .4998641    .5382736          0      1.341
    w2port57 |        807    .5681652    .5686341          0      1.338
    w2port58 |        807    .3643503    .5893492          0      1.457
    w2port59 |        807    .4232416    .7114492          0      1.828
    w2port60 |        807    .2842379    .4663525          0      1.215
-------------+---------------------------------------------------------
    w2port61 |        807    .0871128     .191937          0       .513
    w2port62 |        807    .1263528    .3169893          0   1.333333
    w2port63 |        807    .0886667    .1953804          0       .533
    w2port64 |        807    .1490136    .3394564          0          1
    w2port65 |        807    .2003395    .4561507          0      1.623
-------------+---------------------------------------------------------
    w2port66 |        807    .1687063    .4947921          0      2.267
    w2port67 |        807    .1325898    .3456803          0        1.5
    w2port68 |        807    .3223048    .7450853          0      2.221
    w2port69 |        807    .3223048    .7450853          0      2.221
    w2port70 |        807    .0789343    .2215913          0          1
-------------+---------------------------------------------------------
    w2port71 |        807    .2231879    .5121729          0      1.867
    w2port72 |        807    .1710037    .3767457          0          1
    w2port73 |        807    .2228005    .5313035          0        2.1
    w2port74 |        807    .1929699     .472079          0      1.933
    w2port75 |        807    .1945709    .4780052          0      1.967
-------------+---------------------------------------------------------
    w2port76 |        807    .1490368    .3299804          0          1
    w2port77 |        807    .1961248    .4837904          0          2
    w2port78 |        807    .1019489    .2712447          0   .8227273
    w2port79 |        807    .1450847    .3860117          0   1.170833
    w2port80 |        807    .1450847    .3860117          0   1.170833
-------------+---------------------------------------------------------
    w2port81 |        807    .1450847    .3860117          0   1.170833
    w2port82 |        807    .1450847    .3860117          0   1.170833
    w2port83 |        807    .1182832    .3147038          0   .9545454
    w2port84 |        807    .1182832    .3147038          0   .9545454
    w2port85 |        807    .1182832    .3147038          0   .9545454
-------------+---------------------------------------------------------
    w2port86 |        807    .1182832    .3147038          0   .9545454
    w2port87 |        807    .1182832    .3147038          0   .9545454
    w2port88 |        807    .1182832    .3147038          0   .9545454
    w2port89 |        807    .1239157    .3296897          0          1
    w2port90 |        807    .1208178    .3214475          0       .975
-------------+---------------------------------------------------------
    w2port91 |        807    .1208178    .3214475          0       .975
    w2port92 |        807    .1208178    .3214475          0       .975
    w2port93 |        807           0           0          0          0
    w2port94 |        807           0           0          0          0
    w2port95 |        807    .0774473    .2060561          0       .625
-------------+---------------------------------------------------------
    w2port96 |        807    .1019489    .2712447          0   .8227273
    w2port97 |        807    .1019489    .2712447          0   .8227273
    w2port98 |        807    .1019489    .2712447          0   .8227273
    w2port99 |        807    .1019489    .2712447          0   .8227273
    w2por100 |        807    .1019489    .2712447          0   .8227273
-------------+---------------------------------------------------------
    w2por101 |        807    .2158612    .5743195          0      1.742
    w2por102 |        807    .2519207    .6702592          0      2.033
    w2por103 |        807    .2618339    .6966344          0      2.113
    w2por104 |        807    .2504337    .6663029          0      2.021
    w2por105 |        807    .2230483    .5934415          0        1.8
-------------+---------------------------------------------------------
    w2por106 |        807    .2349442    .6250917          0      1.896
    w2por107 |        807    .1239157    .3296897          0          1
    w2por108 |        807    .1239157    .3296897          0          1
    w2por109 |        807    .1135894    .3022156          0   .9166667
    w2por110 |        807    .1239157    .3296897          0          1
-------------+---------------------------------------------------------
    w2por111 |        807    .2592317    .6897109          0      2.092
    w2por112 |        807    .2978934    .7925741          0      2.404
    w2por113 |        807    .2116481      .56311          0      1.708
    w2por114 |        807    .2245353    .5973978          0      1.812
    w2por115 |        807    .2049566    .5453068          0      1.654
-------------+---------------------------------------------------------
    w2por116 |        807    .2307311    .6138823          0      1.862
    w2por117 |        807    .2297398    .6112447          0      1.854
    w2por118 |        807           0           0          0          0
    w2por119 |        807           0           0          0          0
    w2por120 |        807           0           0          0          0
-------------+---------------------------------------------------------
     ptyprop |        807    .3320942    .2454312   .0111732    .971519
    ptyprops |        807    .1704484    .2148228   .0001248   .9438491
     ppunwtd |        807    .3320942    .2065127     .03125   .9230769
     portpr1 |        807    .3320942    .2185099          0    .929046
     portpr2 |        807    .3320942    .2168431   .0177931   .9325442
-------------+---------------------------------------------------------
     formint |        807    .1878827    .2967392          0    .971519
     formpps |        807    .1232449    .2238717          0   .9438491
       d1int |        807    .0210657    .1041854          0   .8823529
       d2int |        807    .0346964    .1096167          0       .832
       d3int |        807    .0210657    .1072265          0   .9014084
-------------+---------------------------------------------------------
       d4int |        807    .0408922    .1184324          0   .8030303
       d5int |        807    .0272615    .1215489          0    .869403
       d6int |        807    .0247831    .1067746          0        .75
       d7int |        807    .0123916    .0889028          0   .9506173
       d8int |        807    .0495663    .1659233          0    .971519
-------------+---------------------------------------------------------
       d9int |        807    .0223048    .1047506          0   .7352941
      d10int |        807    .0247831    .0947948          0   .6666667
      d11int |        807    .0086741    .0561283          0   .6410257
      d12int |        807    .0074349    .0622694          0   .7132867
      d14int |        807    .0086741    .0668481          0       .848
-------------+---------------------------------------------------------
      d16int |        807    .0285006    .1390249          0   .9407666
       d1pps |        807    .0112849    .0614298          0   .7785467
       d2pps |        807    .0132048    .0585067          0    .692224
       d3pps |        807     .011927    .0771575          0   .8125372
       d4pps |        807     .015681    .0622361          0   .6448576
-------------+---------------------------------------------------------
       d5pps |        807     .015499     .085696          0   .7558615
       d6pps |        807    .0120009    .0621197          0      .5625
       d7pps |        807    .0080475    .0706406          0   .9036732
       d8pps |        807    .0299532    .1303344          0   .9438491
       d9pps |        807    .0114566    .0579358          0   .5406575
-------------+---------------------------------------------------------
      d10pps |        807    .0095891    .0441365          0   .4444444
      d11pps |        807    .0032217     .027171          0   .4109139
      d12pps |        807     .003928    .0364932          0   .5087779
      d14pps |        807    .0045384    .0451629          0    .719104
      d16pps |        807    .0201163    .1136066          0   .8850417
-------------+---------------------------------------------------------
     cabsize |        807    19.48203    6.107544          8         37
       legwt |        807    13.37794    23.65403          0        206
     totalwt |        807    92.42131     131.489          1        630
      lwprop |        807    .2019082    .1643866          0          1
    totalwt2 |        807    55.62949    80.95163          1        454
-------------+---------------------------------------------------------
     lwprop2 |        807    .3321083    .2230194          0          1
         spm |        807    .0570012    .2319888          0          1
        ntot |        807    301.1338    202.0016         51        672
    legshare |        807    .2009924    .1499862   .0063492   .6016427
         ssi |        807     .213962    .1939574          0          1
-------------+---------------------------------------------------------
       absbz |        807    .3360103    .2560362          0          1
       stdbz |        807    .2122672    .1927157          0          1
     coleman |        807    .3371739    .2567902          0          1
          dp |        807    .1822468     .151663          0          1
      holler |        807    .1770886    .1486287          0          1
-------------+---------------------------------------------------------
       zipke |        807    .6673477    .1323717          0          1
     colomer |        807     .213667    .2009588          0          1
    johnston |        807    .2120239    .1920605          0          1
      aspres |        807    .5254027     .499664          0          1
       aspty |        807    .5192069    .4999408          0          1
-------------+---------------------------------------------------------
    npty_leg |        807    8.158612    3.010671          3         19
      formlw |        807    .1071539    .1910586          0          1
     formlws |        807    .0479401    .1477894          0          1
     lwprops |        807    .0677564    .1450263          0          1
         ww2 |        807    .0421314    .2010134          0          1
-------------+---------------------------------------------------------
      maxlwp |        807    .3337952    .1780505   .0952381          1
      minlwp |        807    .1092763    .0959218          0   .3333333
       maxdp |        807    .2555603    .2018106      .0589          1
       mindp |        807    .1280285    .0856742          0      .3333
    threepty |        807    .0916976    .2887776          0          1
-------------+---------------------------------------------------------
        ydev |        807   -2.52e-10    .0751497  -.2881526   .2881526
        xdev |        807    -.130186    .1562409  -.6637681   .4848485

. *     ****************************************************************  *;
. *      Sort on case number, add country names, rename some variables    *;
. *      Note that Germany = 16 not a typo (was listed as West Germany)   *;
. *      Create some variables                                            *;
. *     ****************************************************************  *;
. sort caseno;

. gen str18 countryname=".";

. replace countryname = "Austria" if country==1;
(35 real changes made)

. replace countryname = "Belgium" if country==2;
(100 real changes made)

. replace countryname = "Denmark" if country==3;
(49 real changes made)

. replace countryname = "Finland" if country==4;
(125 real changes made)

. replace countryname = "France" if country==5;
(58 real changes made)

. replace countryname = "Germany" if country==16;
(53 real changes made)

.  replace countryname = "Iceland" if country==6;
(49 real changes made)

.  replace countryname = "Ireland" if country==7;
(25 real changes made)

.  replace countryname = "Italy" if country==8;
(152 real changes made)

.  replace countryname = "Luxembourg" if country==9;
(38 real changes made)

.  replace countryname = "Netherlands" if country==10;
(67 real changes made)

.  replace countryname = "Norway" if country==11;
(24 real changes made)

.  replace countryname = "Portugal" if country==12;
(14 real changes made)

.  replace countryname = "Sweden" if country==14;
(18 real changes made)

. gen countrycode = . ;
(807 missing values generated)

. replace countrycode = 1 if country==1;
(35 real changes made)

. replace countrycode = 2 if country==2;
(100 real changes made)

. replace countrycode = 3 if country==3;
(49 real changes made)

. replace countrycode = 4 if country==4;
(125 real changes made)

. replace countrycode = 5 if country==5;
(58 real changes made)

. replace countrycode = 6 if country==16;
(53 real changes made)

. replace countrycode = 7 if country==6;
(49 real changes made)

.  replace countrycode = 8 if country==7;
(25 real changes made)

.  replace countrycode = 9 if country==8;
(152 real changes made)

.  replace countrycode = 10 if country==9;
(38 real changes made)

.  replace countrycode = 11 if country==10;
(67 real changes made)

.  replace countrycode = 12 if country==11;
(24 real changes made)

.  replace countrycode = 13 if country==12;
(14 real changes made)

.  replace countrycode = 14 if country==14;
(18 real changes made)

. drop portpr1 portpr2 ;

. egen portfolios = rowtotal(port*) ;

. rename ppunwtd portfolioshare;

. rename ptyprop seatshare;

. rename form formateur;

. rename df1 year;

. rename cabsize government_portfolios ;

. rename seats party_seats ;

. sort countrycode caseno;

. egen cabinetcode = group(caseno) ;

. keep portfolios portfolioshare seatshare formateur year countryname countrycode party party_seats government_por
> tfolios cabinetcode;

. gen region = 2;

. gen cowcode = . ;
(807 missing values generated)

.   replace cowcode = 305 if countrycode == 1;
(35 real changes made)

.   replace cowcode = 211 if countrycode == 2;
(100 real changes made)

.   replace cowcode = 390 if countrycode == 3;
(49 real changes made)

.   replace cowcode = 375 if countrycode == 4;
(125 real changes made)

.   replace cowcode = 220 if countrycode == 5;
(58 real changes made)

.   replace cowcode = 255 if countrycode == 6;
(53 real changes made)

.   replace cowcode = 395 if countrycode == 7;
(49 real changes made)

.   replace cowcode = 205 if countrycode == 8;
(25 real changes made)

.   replace cowcode = 325 if countrycode == 9;
(152 real changes made)

.   replace cowcode = 212 if countrycode == 10;
(38 real changes made)

.   replace cowcode = 210 if countrycode == 11;
(67 real changes made)

.   replace cowcode = 385 if countrycode == 12;
(24 real changes made)

.   replace cowcode = 235 if countrycode == 13;
(14 real changes made)

.   replace cowcode = 380 if countrycode == 14;
(18 real changes made)

. egen government_seats = total(party_seats), by(cabinetcode) ;

. gen code = (region*100000) + (countrycode*1000) + cabinetcode ;

. gen presidential = 0 ;

. label var countryname "country name";

. label var countrycode "country code";

. label var region "1=Africa, 2=Western Europe, 3=Latin America";

. label var party_seats "number of legislative seats per party";

. label var party "party number or acronym";

. label var cabinetcode "cabinet code";

. label var code "region, country code, cabinet code";

. label var cowcode "cow code";

. label var portfolios "number of portfolios per party";

. label var formateur "1 = formateur, 0 = otherwise";

. label var presidential "1 = presidential, 0 = parliamentary";

.  label var government_portfolios "number of portfolios in the government";

. label var government_seats "number of seats controlled by government";

. label var seatshare "party share of leg seats controlled by govt";

. label var portfolioshare "party share of govt portfolios";

. label var year "year in which government begins";

. save "C:\Users\sgolder\Dropbox\Portfolio Allocation\replication\Europe.dta", replace;
file C:\Users\sgolder\Dropbox\Portfolio Allocation\replication\Europe.dta saved

. *     ****************************************************************  *;
. *       How large are European cabinets?                                *;
. *     ****************************************************************  *;
. collapse (mean) government_portfolios, by(cabinetcode);

. sum government_portfolios;

    Variable |        Obs        Mean    Std. Dev.       Min        Max
-------------+---------------------------------------------------------
government~s |        268    18.86194     5.85975          8         37

. log close;
      name:  <unnamed>
       log:  C:\Users\sgolder\Dropbox\Portfolio Allocation\replication\warwickdruckman.log
  log type:  text
 closed on:  30 Mar 2017, 13:32:14
------------------------------------------------------------------------------------------------------------------
